# author by LuoQian
# 2022/2/28 16:35
# 数据类型-整型int
from decimal import Decimal

from week02.demo03 import y

a = 10
b = -10
c = 0
print(a, type(a))  # <class 'int'>
print(b, type(b))  # -10 <class 'int'>
print(c, type(c))  # 0 <class 'int'>
print("十进制", 999)
print("二进制", 0b110101110)
print("八进制", 0o776)
print("十六进制", 0x7E)

print("------------------------")
# 数据类型-浮点型
x = 3.1415
print(x, type(x))  # 3.1415 <class 'float'>
Y = 100.0
print(y, type(y))  # 100.0 <class 'float'>
# 浮点型的数据会丢失精度，所以一般不做运算
print(1.1 + 2.2)
print(2.2 + 1.1)  # 3.30000000000000003
print(Decimal("2.2") + Decimal("1.1"))

print("-------------------------------")
# 数据类型-布尔型： True False
b1 = True
b2 = False
print(b1, type(b1))  # True <class 'bool'>
print(b2, type(b2))  # False <class 'bool'>
print(1 != 1)  # False--*
print(1 == 1)  # True
print(True + 1)
print(False + 1)

print("-------------------------")
str1 = '人生苦短，快来学python'
str2 = "python好学，人生短短几个秋"
str3 = '''我是Python程序员，大家好啊'''
str4 = """我是python程序员，大家好啊"""

